<template>
	<u-popup :show="isSelectShow" :round="12" mode="bottom" @close="isSelectShow = false">
		<view class="select-cotent">
			<view class="select-list">
				<view class="select-item" v-for="(item, index) in options" @click="selectItem(item)">
					{{ item.name }}
				</view>
			</view>
			<view class="select-item" @click="isSelectShow = false">
				取消
			</view>
		</view>
	</u-popup>
</template>
<script>

export default {
	data() {
		return {
			isSelectShow: false
		}
	},
	props: {

		options: {
			default: false,
			type: Array
		},
	},
	watch: {

	},
	computed: {

	},
	methods: {
		open() {
			this.isSelectShow = true
		},
		close() {
			this.isSelectShow = false
		},
		selectItem(e) {
			this.$emit('confirmed', e);
			this.close()
		}
	}
}
</script>

<style lang="scss" scoped>
.select-cotent {
	font-size: 34rpx;
	color: #161823;
	background: #f3f3f3;
	overflow: hidden;
	border-radius: 12rpx 12rpx 0 0;
	.select-list {
		margin-bottom: 16rpx;
		background: #fff;
	}

	.select-item {
		padding: 32rpx;
		text-align: center;
		background: #fff;
	}
}
</style>